package com.woniu.user.feign;

import com.woniu.entity.Result;
import com.woniu.user.pojo.User;
import io.swagger.annotations.ApiOperation;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;

/**
 * @author Ma.Lei
 * @description
 * @date 2023/2/21 10:39
 */
@FeignClient(value = "user-service" , path = "user", contextId = "user")
public interface UserFeignClient {
    @GetMapping("/shopGetUserById/{id}")
    public Result<String> shopGetUserById(@PathVariable("id") String id);

    @GetMapping("/getUserByPhone/{phone}")
    @ApiOperation("根据用户手机号获取用户")
    public User getUserByPhone(@PathVariable("phone") String phone);
}

